include ../../../mk/pitchfork.mk

# Local variables
_VER    = 2.7.0
_NAME   = h5py-$(_VER)
_WRKSRC = $(WORKDIR)/$(_NAME)

# Local works
do-install: | $(PREFIX)/var/pkg/$(_NAME)
$(PREFIX)/var/pkg/$(_NAME):
	rm -rf $(STAGING)/$(_NAME)
	mkdir -p $(STAGING)/$(_NAME)
	CFLAGS="$(CFLAGS)" LDFLAGS="$(LDFLAGS)" HDF5_DIR="$(HDF5_ROOT)" \
            $(PIP) install --root $(STAGING)/$(_NAME) --no-deps h5py==$(_VER)
	rsync -aKx $(STAGING)/$(_NAME)/$(PREFIX)/ $(PREFIX)/
	cd $(STAGING)/$(_NAME)$(PREFIX) && find * ! -type d|grep -v '^$$'|sort -r > $@
do-clean: do-flush
do-distclean: do-flush
do-flush:
	rm -rf $(STAGING)/$(_NAME)
